#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Sun Oct 22 15:40:04 2023

@author: liqingsimac
"""
import numpy as np
y = np.linspace(start=-5,stop=5,num=21,endpoint=True)
p = np.exp(y)/(1+np.exp(y))

import matplotlib.pyplot as plt
fig=plt.figure()
ax=fig.add_subplot(111)
ax.plot(y,p,'-')
ax.set_xlabel('y')
ax.set_ylabel('p')

